//
//  PictureCollectionCell.m
//  GameBoss
//
//  Created by dllo on 15/4/22.
//  Copyright (c) 2015年 dllo. All rights reserved.
//

#import "PictureCollectionCell.h"
#define WIDTH self.contentView.frame.size.width
#define HEIGHT self.contentView.frame.size.height

@implementation PictureCollectionCell

-(instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        self.picImage = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, WIDTH, HEIGHT)];
        [self.contentView addSubview:self.picImage];
        [_picImage release];
    
        self.iconPic = [[UIImageView alloc] initWithFrame:CGRectMake(WIDTH * 10/110, HEIGHT * 85/110, WIDTH * 15/110, HEIGHT * 15/110)];
        [self.picImage addSubview:self.iconPic];
        [_iconPic release];
        
        self.picCount = [[UILabel alloc] initWithFrame:CGRectMake(WIDTH * 30/110, HEIGHT * 85/110, WIDTH * 20/110, HEIGHT * 15/110)];
        self.picCount.textColor = [UIColor whiteColor];
        self.picCount.font = [UIFont fontWithName:@"AppleGothic" size:12];
        [self.picImage addSubview:self.picCount];
        [_picCount release];
    }
    
#pragma mark 夜间判断
//    if ([NightMode shareNightMode].isNight) {
//        [[NightMode shareNightMode] loadNightModeInfoFormDisk];
//    }
    
    return self;
    
}
#pragma mark 选取白黑两种模式
- (void)setNightDayModel {
    [NightManager setViewColorWithView:self.contentView];
    
}

- (void)setLightDayModel {
    [NightManager setViewColorWithView:self.contentView];
    
}

-(void)dealloc{
    [_picImage release];
    [_picCount release];
    [_iconPic release];
    [super dealloc];
}

@end
